<script setup>
import { storeToRefs } from 'pinia'
import { useChannelStore } from '../stores'
const channelStore = useChannelStore()
const { list, channelId } = storeToRefs(channelStore)
channelStore.getChannelList()
</script>
<template>
  <ul class="catagtory">
    <li
      @click="channelStore.setId(item.id)"
      :class="{ select: channelId === item.id }"
      v-for="item in list"
      :key="item.id"
    >
      {{ item.name }}
    </li>
  </ul>
</template>
<style scoped></style>
